Skip to content

fix: scope meeting summarization to primary meeting body#85

Merged
AndreRobitaille merged 4 commits intomasterfrom
fix/embedded-committee-minutes-in-summaries
Apr 9, 2026
Merged

fix: scope meeting summarization to primary meeting body#85
AndreRobitaille merged 4 commits intomasterfrom
fix/embedded-committee-minutes-in-summaries

Conversation

@AndreRobitaille
Copy link
Copy Markdown
Owner

Summary

  • City Council packets and minutes contain embedded minutes from subordinate committees (Plan Commission, Room Tax Commission, etc.) included as consent agenda items for acceptance
  • The AI was extracting public comments and item details from those embedded minutes as if they belonged to the Council meeting (e.g., meeting #155 showed Plan Commission and Room Tax Commission public comments as City Council public input)
  • Adds body_name placeholder to the analyze_meeting_content prompt template and a <document_scope> instruction telling the AI to only extract content from the named body's proceedings

Changes

  • app/services/ai/open_ai_service.rb — pass body_name from source meeting into prompt placeholders
  • lib/prompt_template_data.rb — add <document_scope> section with {{body_name}} to the analyze_meeting_content template
  • test/services/ai/open_ai_service_analyze_meeting_test.rb — test that body_name appears in prompt and embedded-minutes warning is present

Deployment note

After deploy, the prompt template in the database needs updating. Either re-seed or manually edit at /admin/prompt_templates. Then re-run SummarizeMeetingJob for affected meetings (e.g., meeting 155).

Test plan

  • New test verifies body_name is interpolated into the prompt
  • New test verifies embedded-minutes scoping language is present
  • Existing analyze_meeting_content test still passes
  • Full suite passes (420 runs, 0 failures)
  • After deploy: re-summarize meeting 155 and verify Plan Commission / Room Tax Commission public comments are excluded

🤖 Generated with Claude Code

AndreRobitaille and others added 4 commits April 9, 2026 04:28
Member.resolve() can map different raw names to the same Member via
alias lookup or title stripping, causing uniqueness violations on
MeetingAttendance. Skip duplicate attendance creation for same member.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Prevents bin/clone-production-db (a destructive data sync tool) from
being accidentally committed to the repository.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
City Council packets and minutes contain embedded minutes from
subordinate committees (Plan Commission, Room Tax Commission, etc.)
included for acceptance. The AI was extracting public comments and
item details from those embedded minutes as if they belonged to the
Council meeting.

Adds body_name to the analyze_meeting_content prompt so the AI knows
which body's proceedings to extract from, and adds a <document_scope>
instruction to explicitly ignore embedded committee content.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@AndreRobitaille AndreRobitaille merged commit ffcc5f0 into master Apr 9, 2026
2 of 3 checks passed
@AndreRobitaille AndreRobitaille deleted the fix/embedded-committee-minutes-in-summaries branch April 9, 2026 14:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant